<style scoped>

</style>

<template>
    <div style="width: 100%;height:calc(100vh - 50px);">
        <van-nav-bar
                title="我的"
                @click-right="myEdit"
        >
            <van-icon name="edit" slot="right"/>
        </van-nav-bar>
        <van-pull-refresh v-model="isLoading" @refresh="onRefresh">
            <van-row >
                <van-col span="6"><div style="text-align: center;margin: 5px 0px;"><img src="../../../public/img/aaa.png" style="height: 60%;width: 60%;"/></div></van-col>
                <van-col span="18">
                    <van-cell :title=userName is-link label="描述信息"/>
                </van-col>

            </van-row>
            <div style="width: 100%;">
                <van-cell-group>
                    <van-cell title="单元格" value="内容"/>
                    <van-cell title="单元格" value="内容" label="描述信息"/>
                </van-cell-group>

                <van-cell title="单元格" is-link />
                <van-cell title="单元格" is-link value="内容" />
                <van-cell title="单元格" is-link arrow-direction="down" value="内容" />

                <van-cell value="内容" icon="shop" is-link>
                    <template slot="title">
                        <span class="custom-text">单元格</span>
                        <van-tag type="danger">标签</van-tag>
                    </template>
                </van-cell>
                <van-cell title="单元格" icon="location" is-link />
                <van-cell title="单元格">
                    <van-icon slot="right-icon" name="search" class="custom-icon" />
                </van-cell>

                <van-cell title="单元格" icon="location" />

                <van-cell title="单元格" icon="location" />
                <van-cell title="单元格" is-link />
                <van-cell title="单元格" is-link value="内容" />
                <van-cell title="单元格" is-link arrow-direction="down" value="内容" />

                <van-cell title="单元格" icon="location" />

                <van-cell title="单元格" icon="location" />
                <van-cell title="单元格" is-link />
                <van-cell title="单元格" is-link value="内容" />
                <van-cell title="单元格" is-link arrow-direction="down" value="内容" />

                <van-cell title="单元格" icon="location" />

                <van-cell title="单元格" icon="location" />
            </div>
        </van-pull-refresh>
    </div>
</template>

<script>
    export default {
        name: "My",
        data() {
            return {
                count: 0,
                isLoading: false,
                userName: ''
            }
        },
        methods: {
            myEdit() {
                let self = this;
                self.$notify({
                    message: "我的设置",
                    duration: 3000
                });
            },
            onRefresh() {
                setTimeout(() => {
                    this.$toast('刷新成功');
                    this.isLoading = false;
                    this.count++;
                }, 500);
            }
        },
        mounted() {
            let self = this;
            let userinfo = self.common.getStorageS("userinfo");
            self.userName = userinfo.userName;
        }
    }

</script>

